//
//  HttpServerCfg.h
//  http_server
//
//  Created by Zirpon Cheung on 15-3-26.
//  Copyright (c) 2015年 Zirpon Cheung. All rights reserved.
//

#ifndef __http_server__HttpServerCfg__
#define __http_server__HttpServerCfg__

#include <iostream>
#include <string>
#include <map>
#include "File.h"
#include "Socket.h"

using namespace std;

struct HttpServerCfgDef
{
    HttpServerCfgDef()
    {
        homeDir = "";
        ip      = "";
        port    = 0;
        back    = 0;
    }
    
    string              homeDir;
    string              ip;
    unsigned short      port;
    unsigned short      back;
};

class HttpServerCfg
{
public:
    static void load(std::string path);
    static struct HttpServerCfgDef getHttpServerCfgDef();
    
private:
    static struct HttpServerCfgDef cfg;
};

#endif /* defined(__http_server__HttpServerCfg__) */
